package com.wwdx.service.impl;

import com.wwdx.wechat.config.BaseWxOpenConfig;
import com.wwdx.wechat.config.open.WxOpenConfig;
import com.wwdx.wechat.handler.*;
import com.wwdx.wechat.handler.open.*;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * @author liguoliang
 * @date 2018/9/17 21:44
 */
@Service
public class FirstWxOpenService extends BaseWxOpenService {

    @Resource
    private WxOpenConfig config;

    @Override
    protected BaseWxOpenConfig getServerConfig() {
        return config;
    }

    @Resource
    private OpenMenuHandler openMenuHandler;
    @Resource
    private OpenSubscribeHandler openSubscribeHandler;
    @Resource
    private OpenUnsubscribeHandler openUnsubscribeHandler;
    @Resource
    private OpenMsgHandler openMsgHandler;
    @Resource
    private OpenScanHandler openScanHandler;

    @Override
    protected AbstractMenuHandler getMenuHandler() {
        return openMenuHandler;
    }

    @Override
    protected AbstractSubscribeHandler getSubscribeHandler() {
        return openSubscribeHandler;
    }

    @Override
    protected AbstractUnsubscribeHandler getUnsubscribeHandler() {
        return openUnsubscribeHandler;
    }

    @Override
    protected AbstractMsgHandler getMsgHandler() {
        return openMsgHandler;
    }

    @Override
    protected AbstractScanHandler getScanHandler() {
        return openScanHandler;
    }
}